package com.dianping.cat.home.router.entity;

import com.dianping.cat.home.router.BaseEntity;
import com.dianping.cat.home.router.IVisitor;



public class DefaultServer
  extends BaseEntity<DefaultServer>
{
  private String m_id;
/*  12 */   private double m_weight = 1.0D;


  private int m_port;


  private boolean m_enable;



/*  22 */   public DefaultServer(String id) { this.m_id = id; }




/*  27 */   public void accept(IVisitor visitor) { visitor.visitDefaultServer(this); }



  public boolean equals(Object obj) {
    if (obj instanceof DefaultServer) {
/*  33 */       DefaultServer _o = (DefaultServer)obj;

/*  35 */       if (!equals(getId(), _o.getId())) {
        return false;
      }

/*  39 */       return true;
    }

/*  42 */     return false;
  }


/*  46 */   public boolean getEnable() { return this.m_enable; }



/*  50 */   public String getId() { return this.m_id; }



/*  54 */   public int getPort() { return this.m_port; }



/*  58 */   public double getWeight() { return this.m_weight; }



  public int hashCode() {
/*  63 */     int hash = 0;

/*  65 */     return hash * 31 + ((this.m_id == null) ? 0 : this.m_id.hashCode());
  }




/*  71 */   public boolean isEnable() { return this.m_enable; }



  public void mergeAttributes(DefaultServer other) {
/*  76 */     assertAttributeEquals(other, "default-server", "id", this.m_id, other.getId());

    this.m_weight = other.getWeight();

/*  80 */     this.m_port = other.getPort();

/*  82 */     this.m_enable = other.getEnable();
  }

  public DefaultServer setEnable(boolean enable) {
/*  86 */     this.m_enable = enable;
/*  87 */     return this;
  }

  public DefaultServer setId(String id) {
/*  91 */     this.m_id = id;
/*  92 */     return this;
  }

  public DefaultServer setPort(int port) {
/*  96 */     this.m_port = port;
/*  97 */     return this;
  }

  public DefaultServer setWeight(double weight) {
/* 101 */     this.m_weight = weight;
/* 102 */     return this;
  }

  public DefaultServer() {}
}


/* Location:              /Users/hanfei/Documents/apache-tomcat-9.0.24/webapps/cat/WEB-INF/classes/!/com/dianping/cat/home/router/entity/DefaultServer.class
 * Java compiler version: 7 (51.0)
 * JD-Core Version:       1.0.7
 */